|
Now we want to consider the difference between hiding and overwriting in more detail. First, have a look at inherited items of the declarative part of an entity/architecture. They can be redefined whereby the old items are hidden by the new ones. The old items are not directly visible anymore - every use of an item's name refers to the new item. But the old items can be accessed by a qualified notation xx.yy, where xx denotes the name of the parent entity/architecture and yy denotes the name of the hidden item. It is necessary that a hidden item still exists, because it might be needed by a second item, which is also inherited but not redefined. Take a look at the example on the right. In architecture A two procedures P1 and P2 are defined, where P2 calls P1. The derived architecture A_SUB inherits both procedures, but redefines P1. Now the question is, which version of P1 will be called by P2. The designers of Objective VHDL decided to follow the concept of static binding: inherited items are still bound to used items of their declaration area. So in the example the inherited procedure P2 will call the hidden procedure P1. |
architecture A of AN_ENTITY_E is
Inherited labeled concurrent statements are different. They also can be redefined but then the old concurrent statement is not hidden but overwritten and can not be accessed anymore. Take a look on the next page, where the necessity of overwriting will get clear. |